﻿using Rabbit.Contracts.Interface;
using Rabbit.Domain.Entity;
using Rabbit.Domain.IRepository;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Rabbit.Service
{
    public class MachinService: IMachinService
    {
        private readonly IMachinRepository _machinRepository;

        public MachinService(IMachinRepository machinRepository)
        {
            _machinRepository = machinRepository;
        }

        public int GeMachinAdd(Machining Machin)
        {
            return _machinRepository.GeMachinAdd(Machin);
        }

        
        public dynamic GetMachinFind(int id)
        {
            return _machinRepository.GetMachinFind(id);
        }

        public List<Machining> GetMachinShow(int id)
        {
            return _machinRepository.GetMachinShow(id);
        }

        public int GetMachinUpd(Machining Machin)
        {
            return _machinRepository.GetMachinUpd(Machin);
        }


        public List<Gongyingshang> GetGongyingshangShow()
        {
            return _machinRepository.GetGongyingshangShow();
        }

        public List<Machiningenterprise> GetMachiningenterpriseShow()
        {
            return _machinRepository.GetMachiningenterpriseShow();
        }

        public int GetGongyingshangXiu(Machiningenterprise Machin)
        {
            return _machinRepository.GetGongyingshangXiu(Machin);
        }



    }
}
